using System.Collections;
using System.Collections.Generic;
using UnityEngine;
using static VRig;
public class VTouchInteractNode : MonoBehaviour
{
    public VTouchManager manager;
    public SphereCollider touchCollider;//这个地方就该维护变体了
    public RigIKUnit IKUnit;
    private void OnTriggerEnter(Collider other)
    {

    }

    public void OnMouseRayEnter()
    {
        print(IKUnit);
    }

    public void OnAdd(VTouchManager manager, RigIKUnit rigIKUnit)
    {
        this.manager = manager;
        touchCollider = gameObject.UniqueComponent<SphereCollider>();
        //这里是一些基本的配置, 当然偏移量这些还得微调
        touchCollider.radius = 0.1f;
        IKUnit = rigIKUnit;
    }
    public void OnRemove()
    {
        this.manager = null;
        gameObject.RemoveComponent<SphereCollider>();
    }
}
